﻿using AutoRetailsDLL.Workers;
using AutoRetailsDLL.Workers.JingDong;
using AutoRetailsDLL.Workers.PinDuoDuo;
using AutoRetailsDLL.Workers.TianMao;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace AutoRetails
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private async void Login_Click(object sender, EventArgs e)
        {

            PinDuoDuoWorker pinDuoDuoWorker = new PinDuoDuoWorker();
            pinDuoDuoWorker.InitPinDuoDuoAsync();
            Task<WorkResult> workResult=  pinDuoDuoWorker.Login("13810949001", "Wopashui3928");
            workResult.Wait(10000);
            //TianMaoWorker tianMaoWorker = new TianMaoWorker();
            //await tianMaoWorker.InitPinDuoDuoAsync();
            //await tianMaoWorker.Login("互引互语专卖店:向阳", "jiawen168");
        }

        private async void button1_Click(object sender, EventArgs e)
        {
           // await PinDuoDuoWorker.Instance.Login("13810949001", "Wopashui3919");
        }

        private async void SaveCookies_Click(object sender, EventArgs e)
        {
            PinDuoDuoAddGoodModel_In param=new PinDuoDuoAddGoodModel_In();
            param.onlineGoodsTitle = "苹果X手机壳全包7前卫7plus质感彩绘卡通保护套液态硅胶透明潮流";
            param.brand = "JSOWE";
            //param.platformBrand = "8848";
            param.modelCode.Add(new Modelcode() {pddApplyBrand= "360", pddApplyModel ="C5"});
            param.modelCode.Add(new Modelcode() { pddApplyBrand = "360", pddApplyModel = "VIZZA" });
            param.goodsTexture = "亚克力";
            param.goodsDesign = "钱包式";
            param.fashionElement = "定制";
            param.goodsStyle = "商务";
            param.specifications = "型号-颜色";
            param.spec1 = new List<string>() { "苹果7", "苹果8" };
            param.spec2 = new List<string>() { "图案1", "图案2"};
            param.freightTemplate = "测试包邮";
            param.shipmentTime = "48小时";
            Materialfile materialfile_master = new Materialfile();
            materialfile_master.materialType = "master";
            materialfile_master.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", skuCode = "1" });
            materialfile_master.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\2.jpg", skuCode = "2" });
            materialfile_master.specList.Add(new Speclist() {hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\3.jpg", skuCode = "3" });
            param.materialFile.Add(materialfile_master);

            Materialfile materialfile_sku = new Materialfile();
            materialfile_sku.materialType = "sku";
            materialfile_sku.specList.Add(new Speclist() { stockNum=500,price=48.00f,singlePrice=50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", skuCode = "1" });
            materialfile_sku.specList.Add(new Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\2.jpg" , skuCode = "2" });
            materialfile_sku.specList.Add(new Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\3.jpg" , skuCode = "3" });
            materialfile_sku.specList.Add(new Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\3.jpg", skuCode = "4" });
            param.materialFile.Add(materialfile_sku);
            param.goodsReferencePrice = "52.9";
            param.fullDiscount = "9.8";

            Materialfile materialfile_detail = new Materialfile();
            materialfile_detail.materialType = "detail";
            materialfile_detail.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            materialfile_detail.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            materialfile_detail.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            materialfile_detail.specList.Add(new Speclist() {hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            param.materialFile.Add(materialfile_detail);

            Materialfile materialfile_whiteBg = new Materialfile();
            materialfile_whiteBg.materialType = "whiteBg";
            materialfile_whiteBg.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\2.jpg", vid = "1" });
            param.materialFile.Add(materialfile_whiteBg);
            //PinDuoDuoWorker pinDuoDuoWorker=new PinDuoDuoWorker();
            WorkerConfig  workerConfig = new WorkerConfig();
            workerConfig.pictureWaitTime = 2000;
            workerConfig.wordWaitTime = 500;
            workerConfig.outTime = 800000;
            string paramjson2 =JsonConvert.SerializeObject(param);
            string paramjson = @"{
  ""shopUid"": null,
  ""outGoodsSn"": null,
  ""spuId"": null,
  ""craft"": null,
  ""productionCompany"": null,
  ""goodsColor"": null,
  ""goodsPattern"": null,
  ""onlineGoodsTitle"": ""苹果X手机壳全包7前卫7plus质感彩绘卡通保护套液态硅胶透明潮流"",
  ""brand"": ""JSOWE"",
  ""platformBrand"": null,
  ""modelCode"": [
    {
      ""pddApplyBrand"": ""8848"",
      ""pddApplyModel"": ""M4""
    },
    {
      ""pddApplyBrand"": ""8848"",
      ""pddApplyModel"": ""M5""
    }
  ],
  ""goodsTexture"": ""亚克力"",
  ""goodsDesign"": ""全包式"",
  ""fashionElement"": ""定制"",
  ""goodsStyle"": ""商务"",
  ""goodsReferencePrice"": ""52.9"",
  ""fullDiscount"": ""9.8"",
  ""shipmentTime"": null,
  ""supply7DayReturn"": 0,
  ""isDraft"": 0,
  ""specifications"": ""型号-颜色"",
  ""spec1"": [
    ""苹果7"",
    ""苹果8""
  ],
  ""spec2"": [
    ""图案1"",
    ""图案2""
  ],
  ""materialFile"": [
    {
      ""materialType"": ""master"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\2.jpg"",
          ""hashCode"": 0,
          ""vid"": ""2"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\3.jpg"",
          ""hashCode"": 0,
          ""vid"": ""3"",
          ""skuCode"": null
        }
      ]
    },
    {
      ""materialType"": ""sku"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\2.jpg"",
          ""hashCode"": 0,
          ""vid"": ""2"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\3.jpg"",
          ""hashCode"": 0,
          ""vid"": ""3"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\3.jpg"",
          ""hashCode"": 0,
          ""vid"": ""4"",
          ""skuCode"": null
        }
      ]
    },
    {
      ""materialType"": ""detail"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        }
      ]
    },
    {
      ""materialType"": ""whiteBg"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\2.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        }
      ]
    }
  ]
}";
            string config_json=JsonConvert.SerializeObject(workerConfig);
            Task<WorkResult> workResult = PinDuoDuoWorker.Instance.AddGood(paramjson2, config_json);
            //pinDuoDuoWorker.SetParam(param);
            //Task<WorkResult> workResult= pinDuoDuoWorker.TestAddGood();
            //workResult.Wait(1000000);
            //PinDuoDuoWorker.Instance.SetParam(param);
            //string result= await PinDuoDuoWorker.Instance.AddGood(param);
            //MessageBox.Show(result);
        }

        

        private async void TianMaoLogin_Click(object sender, EventArgs e)
        {
            await TianMaoWorker.Instance.Login("互引互语专卖店:向阳", "jiawen168");
        }

        private async void TianMaoAddGood_Click(object sender, EventArgs e)
        {
            TianMaoAddGoodModel_In param=new TianMaoAddGoodModel_In();
            param.onlineGoodsTitle = "苹果X手机壳全包7前卫7plus质感彩绘卡通保护套液态硅胶透明潮流";
            param.brand = "互引";
            //param.platformBrand = "8848";
            param.modelCode.Add(new TianMaoAddGoodModel_In.Modelcode() { tianMaoApplyBrand = "360", tianMaoApplyModel = "M4" });
            param.modelCode.Add(new TianMaoAddGoodModel_In.Modelcode() { tianMaoApplyBrand = "360", tianMaoApplyModel = "M5" });
            param.goodsTexture = "亚克力";
            param.goodsDesign = "支架式";
            param.fashionElement = "定制";
            param.platformBrand = "360";
            param.goodsStyle = "商务";
            param.isBiodegradable = "是";
            param.specifications = "型号-颜色";
            param.productionCompany = "中国为名公司";
            param.isHuanBao = "是";
            param.function = "可插卡";
            param.spec1 = new List<string>() { "苹果7", "苹果8" };
            param.spec2 = new List<string>() { "图案1", "图案2" };
            param.freightTemplate = "测试包邮";
            param.shipmentTime = "48小时";
            TianMaoAddGoodModel_In.Materialfile materialfile_master = new TianMaoAddGoodModel_In.Materialfile();
            materialfile_master.materialType = "master";
            materialfile_master.specList.Add(new TianMaoAddGoodModel_In.Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", skuCode = "1" });
            materialfile_master.specList.Add(new TianMaoAddGoodModel_In.Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\2.jpg", skuCode = "2" });
            materialfile_master.specList.Add(new TianMaoAddGoodModel_In.Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\3.jpg", skuCode = "3" });
            param.materialFile.Add(materialfile_master);

            TianMaoAddGoodModel_In.Materialfile materialfile_sku = new TianMaoAddGoodModel_In.Materialfile();
            materialfile_sku.materialType = "sku";
            materialfile_sku.specList.Add(new TianMaoAddGoodModel_In.Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", skuCode = "1" });
            materialfile_sku.specList.Add(new TianMaoAddGoodModel_In.Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\2.jpg", skuCode = "2" });
            materialfile_sku.specList.Add(new TianMaoAddGoodModel_In.Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\3.jpg", skuCode = "3" });
            materialfile_sku.specList.Add(new TianMaoAddGoodModel_In.Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\3.jpg", skuCode = "4" });
            param.materialFile.Add(materialfile_sku);
            param.goodsReferencePrice = "52.9";
            param.fullDiscount = "9.8";

            TianMaoAddGoodModel_In.Materialfile materialfile_detail = new TianMaoAddGoodModel_In.Materialfile();
            materialfile_detail.materialType = "detail";
            materialfile_detail.specList.Add(new TianMaoAddGoodModel_In.Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", skuCode = "1" });
            materialfile_detail.specList.Add(new TianMaoAddGoodModel_In.Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", skuCode = "1" });
            materialfile_detail.specList.Add(new TianMaoAddGoodModel_In.Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", skuCode = "1" });
            materialfile_detail.specList.Add(new TianMaoAddGoodModel_In.Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", skuCode = "1" });
            param.materialFile.Add(materialfile_detail);

            TianMaoAddGoodModel_In.Materialfile materialfile_whiteBg = new TianMaoAddGoodModel_In.Materialfile();
            materialfile_whiteBg.materialType = "whiteBg";
            materialfile_whiteBg.specList.Add(new TianMaoAddGoodModel_In.Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\2.jpg", skuCode = "1" });
            param.materialFile.Add(materialfile_whiteBg);
            //PinDuoDuoWorker pinDuoDuoWorker=new PinDuoDuoWorker();
            string json = @"
            {
  ""shopUid"": ""S16668532339611502"",
  ""onlineGoodsTitle"": ""1.XXQ适用于华为超薄肤感耐脏透明壳"",
  ""goodsModel"": ""苹果13"",
  ""goodsMobileModel"": ""苹果13"",
  ""otherInfo"": {
    ""是否可降解"": ""是"",
    ""是否使用环保材质"": ""含环保材料"",
    ""是否支持5G信号"": ""是"",
    ""视频id"": -1
  },
  ""outGoodsSn"": ""BLKOPPOA93HE1XXXX"",
  ""spuId"": """",
  ""brand"": ""互引"",
  ""goodsDesign"": ""支架式"",
  ""isFolt"": 1,
  ""goodsTexture"": ""蚕丝"",
  ""goodsStyle"": ""简约"",
  ""goodsPattern"": """",
  ""goodsColor"": """",
  ""productionCompany"": ""深圳佳文科技"",
  ""craft"": """",
  ""goodsTextureName"": """",
  ""function"": """",
  ""wareLocation"": ""大陆及港澳台/广东/深圳"",
  ""goodsLightSpot"": """",
  ""shopCategory"": """",
  ""goodsMobileModel"": """",
  ""shipmentTime"": ""24小时"",
  ""customerMobile"": """",
  ""supply7DayReturn"": -1410065407,
  ""isDraft"": 0,
  ""presellType"": -1410065407,
  ""fashionElement"": ""文字"",
  ""goodsReferencePrice"": 20.88,
  ""fullDiscount"": 9.30,
  ""freightTemplate"": ""测试包邮"",
  ""specifications"": ""型号-颜色"",
  ""spec1"": [
    ""iPhone 15"",
    ""iPhone 13""
  ],
  ""spec2"": [
    ""背景女孩-草紫色"",
    ""背景女孩-淡红色""
  ],
  ""maximumPerOrder"": -1,
  ""limitPerBuyer"": -1,
  ""discount"": 0,
  ""materialFile"": [
    {
      ""materialType"": ""sku"",
      ""specList"": [
        {
          ""spec"": ""背景女孩-草紫色"",
          ""specModel"": ""iPhone 12"",
          ""price"": 13.80,
          ""stockNum"": 500,
          ""discount"": 97.0,
          ""textureCode"": ""玻璃壳"",
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg"",
          ""LocalPath"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": 0,
          ""skuCode"": ""玻璃壳-苹果12-草紫色-奥特曼""
        },
        {
          ""spec"": ""背景女孩-草紫色"",
          ""specModel"": ""iPhone 13"",
          ""price"": 13.80,
          ""stockNum"": 500,
          ""discount"": 97.0,
          ""textureCode"": ""玻璃壳"",
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg"",
          ""LocalPath"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": 0,
          ""skuCode"": ""玻璃壳-苹果13-草紫色-奥特曼""
        },
        {
          ""spec"": ""背景女孩-淡红色"",
          ""specModel"": ""iPhone 12"",
          ""price"": 13.80,
          ""stockNum"": 500,
          ""discount"": 97.0,
          ""textureCode"": ""玻璃壳"",
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg"",
          ""LocalPath"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": 0,
          ""skuCode"": ""玻璃壳-苹果12-淡红色-奥特曼""
        },
        {
          ""spec"": ""背景女孩-淡红色"",
          ""specModel"": ""iPhone 13"",
          ""price"": 13.80,
          ""stockNum"": 500,
          ""discount"": 97.0,
          ""textureCode"": ""玻璃壳"",
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg"",
          ""LocalPath"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": 0,
          ""skuCode"": ""玻璃壳-苹果13-淡红色-奥特曼""
        }
      ]
    },
    {
      ""materialType"": ""master"",
      ""specList"": [
        {
          ""hashCode"": 0,
          ""vid"": 0,
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg""
        }
      ]
    },
    {
      ""materialType"": ""long_master"",
      ""specList"": [
        
      ]
    },
    {
      ""materialType"": ""detail"",
      ""specList"": [
        {
          ""hashCode"": 0,
          ""vid"": 0,
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg""
        },
        {
          ""hashCode"": 0,
          ""vid"": 0,
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg""
        },
        {
          ""hashCode"": 0,
          ""vid"": 0,
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg""
        },
        {
          ""hashCode"": 0,
          ""vid"": 0,
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg""
        },
        {
          ""hashCode"": 0,
          ""vid"": 0,
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg""
        },
        {
          ""hashCode"": 0,
          ""vid"": 0,
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg""
        },
        {
          ""hashCode"": 0,
          ""vid"": 0,
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg""
        }
      ]
    },
    {
      ""materialType"": ""whiteBg"",
      ""specList"": [
        {
          ""hashCode"": 0,
          ""vid"": 0,
          ""imageName"": ""C:\\Users\\晶晶晶\\Desktop\\1.jpg""
        }
      ]
    }
  ],
  ""modelCode"": [
    {
      ""tianMaoApplyBrand"": ""Apple/苹果"",
      ""tianMaoApplyModel"": ""iPhone 12""
    },
    {
      ""tianMaoApplyBrand"": ""Apple/苹果"",
      ""tianMaoApplyModel"": ""iPhone 13""
    }
  ]
}
";
            TianMaoAddGoodModel_In tianMaoAddGoodModel_In = JsonConvert.DeserializeObject<TianMaoAddGoodModel_In>(json);
            WorkerConfig workerConfig = new WorkerConfig();
            workerConfig.pictureWaitTime = 2000;
            workerConfig.wordWaitTime = 500;
            workerConfig.outTime = 800000;
            WorkResult result= TianMaoWorker.Instance.AddGood(tianMaoAddGoodModel_In, workerConfig);
        }
        private void JingDongLogin_Click(object sender, EventArgs e)
        {

            JingDongWorker pinDuoDuoWorker = new JingDongWorker();
            pinDuoDuoWorker.InitPinDuoDuoAsync();
            Task<WorkResult> workResult = pinDuoDuoWorker.Login("嘉昌科技08", "Liao789456");
            workResult.Wait(10000);
            //TianMaoWorker tianMaoWorker = new TianMaoWorker();
            //await tianMaoWorker.InitPinDuoDuoAsync();
            //await tianMaoWorker.Login("互引互语专卖店:向阳", "jiawen168");
        }

        private void JingDongAddGood_Click(object sender, EventArgs e)
        {
            PinDuoDuoAddGoodModel_In param = new PinDuoDuoAddGoodModel_In();
            param.supply7DayReturn = 1;
            param.onlineGoodsTitle = "苹果X手机壳全包7前卫7plus质感彩绘卡通保护套液态硅胶透明潮流";
            param.brand = "越厷-河源市华迪网络科技有限公司";
            //param.platformBrand = "8848";
            param.modelCode.Add(new Modelcode() { pddApplyBrand = "Apple", pddApplyModel = "C5" });
            param.modelCode.Add(new Modelcode() { pddApplyBrand = "Apple", pddApplyModel = "C5" });
            param.goodsTexture = "铝合金";
            param.goodsDesign = "钱包式";
            param.fashionElement = "定制";
            param.goodsStyle = "简约风";
            param.specifications = "型号-颜色";
            param.spec1 = new List<string>() { "苹果7", "苹果8" };
            param.spec2 = new List<string>() { "图案1", "图案2" };
            param.freightTemplate = "测试包邮";
            param.shipmentTime = "48小时";
            Materialfile materialfile_master = new Materialfile();
            materialfile_master.materialType = "master";
            materialfile_master.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", skuCode = "1" });
            materialfile_master.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\2.jpg", skuCode = "2" });
            materialfile_master.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\3.jpg", skuCode = "3" });
            param.materialFile.Add(materialfile_master);

            Materialfile materialfile_sku = new Materialfile();
            materialfile_sku.materialType = "sku";
            materialfile_sku.specList.Add(new Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\4.jpg", skuCode = "1" });
            materialfile_sku.specList.Add(new Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\5.jpg", skuCode = "2" });
            materialfile_sku.specList.Add(new Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\6.jpg", skuCode = "3" });
            materialfile_sku.specList.Add(new Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, imageName = @"C:\\Users\\晶晶晶\\Desktop\\6.jpg", skuCode = "4" });
            param.materialFile.Add(materialfile_sku);
            param.goodsReferencePrice = "52.9";
            param.fullDiscount = "9.8";

            Materialfile materialfile_detail = new Materialfile();
            materialfile_detail.materialType = "detail";
            materialfile_detail.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            materialfile_detail.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            materialfile_detail.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            materialfile_detail.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            param.materialFile.Add(materialfile_detail);

            Materialfile materialfile_whiteBg = new Materialfile();
            materialfile_whiteBg.materialType = "whiteBg";
            materialfile_whiteBg.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\4.jpg", vid = "1" });
            param.materialFile.Add(materialfile_whiteBg);
            //PinDuoDuoWorker pinDuoDuoWorker=new PinDuoDuoWorker();
            WorkerConfig workerConfig = new WorkerConfig();
            workerConfig.pictureWaitTime = 2000;
            workerConfig.wordWaitTime = 500;
            workerConfig.outTime = 800000;
            string paramjson2 = JsonConvert.SerializeObject(param);
            string paramjson = @"{
  ""shopUid"": null,
  ""outGoodsSn"": null,
  ""spuId"": null,
  ""craft"": null,
  ""productionCompany"": null,
  ""goodsColor"": null,
  ""goodsPattern"": null,
  ""onlineGoodsTitle"": ""苹果X手机壳全包7前卫7plus质感彩绘卡通保护套液态硅胶透明潮流"",
  ""brand"": ""JSOWE"",
  ""platformBrand"": null,
  ""modelCode"": [
    {
      ""pddApplyBrand"": ""8848"",
      ""pddApplyModel"": ""M4""
    },
    {
      ""pddApplyBrand"": ""8848"",
      ""pddApplyModel"": ""M5""
    }
  ],
  ""goodsTexture"": ""亚克力"",
  ""goodsDesign"": ""全包式"",
  ""fashionElement"": ""定制"",
  ""goodsStyle"": ""商务"",
  ""goodsReferencePrice"": ""52.9"",
  ""fullDiscount"": ""9.8"",
  ""shipmentTime"": null,
  ""supply7DayReturn"": 0,
  ""isDraft"": 0,
  ""specifications"": ""型号-颜色"",
  ""spec1"": [
    ""苹果7"",
    ""苹果8""
  ],
  ""spec2"": [
    ""图案1"",
    ""图案2""
  ],
  ""materialFile"": [
    {
      ""materialType"": ""master"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\2.jpg"",
          ""hashCode"": 0,
          ""vid"": ""2"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\3.jpg"",
          ""hashCode"": 0,
          ""vid"": ""3"",
          ""skuCode"": null
        }
      ]
    },
    {
      ""materialType"": ""sku"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\2.jpg"",
          ""hashCode"": 0,
          ""vid"": ""2"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\3.jpg"",
          ""hashCode"": 0,
          ""vid"": ""3"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\3.jpg"",
          ""hashCode"": 0,
          ""vid"": ""4"",
          ""skuCode"": null
        }
      ]
    },
    {
      ""materialType"": ""detail"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        }
      ]
    },
    {
      ""materialType"": ""whiteBg"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\2.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        }
      ]
    }
  ]
}";
            string config_json = JsonConvert.SerializeObject(workerConfig);
            Task<WorkResult> workResult = JingDongWorker.Instance.AddGood(paramjson2, config_json);
        }
        private async void SendCommand_Click(object sender, EventArgs e)
        {
            TianMaoWorker.Instance.执行命令(textBox1.Text);
        }
        private void SendCommand2_Click(object sender, EventArgs e)
        {
            TianMaoWorker.Instance.执行命令2(textBox1.Text);
        }

        private void ClickScreen_Click(object sender, EventArgs e)
        {
            int x =int.Parse(ClickX.Text);
            int y = int.Parse(ClickY.Text);
            TianMaoWorker.Instance.点击屏幕_右键(x, y);
            
        }

        private void ClickScreen_Right_Click(object sender, EventArgs e)
        {
            int x = int.Parse(ClickX.Text);
            int y = int.Parse(ClickY.Text);
            TianMaoWorker.Instance.点击屏幕_左键(x, y);
        }

        private void KeyBordSend_Click(object sender, EventArgs e)
        {
            TianMaoWorker.Instance.键盘输入(KeyBoardText.Text);
        }

        private void ClickElement_Click(object sender, EventArgs e)
        {
            TianMaoWorker.Instance.点击元素_左键(textBox1.Text);
        }

        private void button2_Click(object sender, EventArgs e)
        {
            TianMaoWorker.Instance.点击元素_右键(textBox1.Text);
        }

        private void button3_Click(object sender, EventArgs e)
        {

            TEMUWorker temuWorker = new TEMUWorker();
            temuWorker.InitPinDuoDuoAsync();
            Task<WorkResult> workResult = temuWorker.Login("17731691338", "hzgbupt@001");
            workResult.Wait(10000);
        }

        private void button4_Click(object sender, EventArgs e)
        {
            TEMUAddGoodModel_In param = new TEMUAddGoodModel_In();
            param.supply7DayReturn = 1;
            param.onlineGoodsTitle = "苹果X手机壳全包7前卫7plus质感彩绘卡通保护套液态硅胶透明潮流";
            //param.brand = "越厷-河源市华迪网络科技有限公司";
            //param.platformBrand = "8848";
            param.modelCode.Add(new Modelcode() { pddApplyBrand = "Apple", pddApplyModel = "C5" });
            param.modelCode.Add(new Modelcode() { pddApplyBrand = "Apple", pddApplyModel = "C5" });
            param.MadeInCountry = "中国大陆";
            param.MadeInProvince = "安徽省";
            param.goodsTexture = "铝合金";
            param.goodsDesign = "钱包式";
            param.fashionElement = "流苏";
            param.goodsStyle = "简约风";
            param.haveBracket = "是";
            param.haveCameraProtection = "是";
            param.shellProcess = "注塑";
            param.printingProcess = "无印花";
            param.specifications = "型号-颜色";
            param.longestSide = "10";
            param.secondLongestSide = "9";
            param.shortestSide = "5";
            param.weight = "25";
            param.spec1 = new List<string>() { "iPhone 14 Pro Max", "iPhone 14 Pro" };
            param.spec2 = new List<string>() { "红色", "蓝色" };
            param.freightTemplate = "测试包邮";
            param.shipmentTime = "48小时";
            Materialfile materialfile_master = new Materialfile();
            materialfile_master.materialType = "master";
            materialfile_master.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", skuCode = "1" });
            materialfile_master.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\28.jpg", skuCode = "2" });
            materialfile_master.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\3.jpg", skuCode = "3" });
            materialfile_master.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\29.jpg", skuCode = "2" });
            materialfile_master.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\30.jpg", skuCode = "3" });
            param.materialFile.Add(materialfile_master);

            Materialfile materialfile_sku = new Materialfile();
            materialfile_sku.materialType = "sku";
            materialfile_sku.specList.Add(new Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f,priceUnit= "USD", imageName = @"C:\\Users\\晶晶晶\\Desktop\\4.jpg", skuCode = "1" });
            materialfile_sku.specList.Add(new Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, priceUnit = "USD", imageName = @"C:\\Users\\晶晶晶\\Desktop\\5.jpg", skuCode = "2" });
            materialfile_sku.specList.Add(new Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, priceUnit = "USD", imageName = @"C:\\Users\\晶晶晶\\Desktop\\6.jpg", skuCode = "3" });
            materialfile_sku.specList.Add(new Speclist() { stockNum = 500, price = 48.00f, singlePrice = 50.00f, priceUnit = "USD", imageName = @"C:\\Users\\晶晶晶\\Desktop\\60.jpg", skuCode = "3" });
            param.materialFile.Add(materialfile_sku);
            param.goodsReferencePrice = "52.9";
            param.fullDiscount = "9.8";

            Materialfile materialfile_detail = new Materialfile();
            materialfile_detail.materialType = "detail";
            materialfile_detail.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            materialfile_detail.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            materialfile_detail.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            materialfile_detail.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\1.jpg", vid = "1" });
            param.materialFile.Add(materialfile_detail);

            Materialfile materialfile_whiteBg = new Materialfile();
            materialfile_whiteBg.materialType = "whiteBg";
            materialfile_whiteBg.specList.Add(new Speclist() { hashCode = 0, imageName = @"C:\\Users\\晶晶晶\\Desktop\\4.jpg", vid = "1" });
            param.materialFile.Add(materialfile_whiteBg);
            //PinDuoDuoWorker pinDuoDuoWorker=new PinDuoDuoWorker();
            WorkerConfig workerConfig = new WorkerConfig();
            workerConfig.pictureWaitTime = 2000;
            workerConfig.wordWaitTime = 500;
            workerConfig.outTime = 800000;
            string paramjson2 = JsonConvert.SerializeObject(param);
            string paramjson = @"{
  ""shopUid"": null,
  ""outGoodsSn"": null,
  ""spuId"": null,
  ""craft"": null,
  ""productionCompany"": null,
  ""goodsColor"": null,
  ""goodsPattern"": null,
  ""onlineGoodsTitle"": ""苹果X手机壳全包7前卫7plus质感彩绘卡通保护套液态硅胶透明潮流"",
  ""brand"": ""JSOWE"",
  ""platformBrand"": null,
  ""modelCode"": [
    {
      ""pddApplyBrand"": ""8848"",
      ""pddApplyModel"": ""M4""
    },
    {
      ""pddApplyBrand"": ""8848"",
      ""pddApplyModel"": ""M5""
    }
  ],
  ""goodsTexture"": ""亚克力"",
  ""goodsDesign"": ""全包式"",
  ""fashionElement"": ""定制"",
  ""goodsStyle"": ""商务"",
  ""goodsReferencePrice"": ""52.9"",
  ""fullDiscount"": ""9.8"",
  ""shipmentTime"": null,
  ""supply7DayReturn"": 0,
  ""isDraft"": 0,
  ""specifications"": ""型号-颜色"",
  ""spec1"": [
    ""苹果7"",
    ""苹果8""
  ],
  ""spec2"": [
    ""图案1"",
    ""图案2""
  ],
  ""materialFile"": [
    {
      ""materialType"": ""master"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\2.jpg"",
          ""hashCode"": 0,
          ""vid"": ""2"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\3.jpg"",
          ""hashCode"": 0,
          ""vid"": ""3"",
          ""skuCode"": null
        }
      ]
    },
    {
      ""materialType"": ""sku"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\2.jpg"",
          ""hashCode"": 0,
          ""vid"": ""2"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\3.jpg"",
          ""hashCode"": 0,
          ""vid"": ""3"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 48.0,
          ""singlePrice"": 50.0,
          ""stockNum"": 500,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\3.jpg"",
          ""hashCode"": 0,
          ""vid"": ""4"",
          ""skuCode"": null
        }
      ]
    },
    {
      ""materialType"": ""detail"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        },
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\1.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        }
      ]
    },
    {
      ""materialType"": ""whiteBg"",
      ""specList"": [
        {
          ""spec"": null,
          ""specModel"": null,
          ""tmSpecModel"": null,
          ""price"": 0.0,
          ""singlePrice"": 0.0,
          ""stockNum"": 0,
          ""discount"": 0.0,
          ""textureCode"": null,
          ""imageName"": ""E:\\\谷歌下载\\\2.jpg"",
          ""hashCode"": 0,
          ""vid"": ""1"",
          ""skuCode"": null
        }
      ]
    }
  ]
}";
            string config_json = JsonConvert.SerializeObject(workerConfig);
            Task<WorkResult> workResult = TEMUWorker.Instance.AddGood(paramjson2, config_json);
        }
    }
}
